﻿namespace CRM.Business.Services
{
    using System.Collections.Generic;
    using CRM.DataAccess.DAOs;
    using CRM.DataAccess.Entities;

    public static class ItemService
    {
        /// Gets or sets the role DAO.
        private static ItemDAO ItemDAO = new ItemDAO();

        //Delete Item
        public static int DeleteItem(long itemID)
        {
            return ItemDAO.DeleteItem(itemID);
        }
        //Get Item by ID
        public static ITEM GetItemByID(long? ID)
        {
            return ItemDAO.GetItemByID(ID);
        }
        //Add new item
        public static int AddNewItem(ITEM item, List<ITEM_DETAIL> itemDetails)
        {
            return ItemDAO.AddNewItem(item, itemDetails);
        }
       //Get List item detail by Item_ID
        public static List<ITEM_DETAILS> GetListItemDetailByItemID(long? itemID)
        {
            return ItemDAO.GetListItemDetailByItemID(itemID);
        }
       
    }
}
